xend: fix insufficient quoting in tapdisk
authorPhilipp Hahn <hahn@univention.de>
Thu, 8 Dec 2011 17:15:16 +0000 (17:15 +0000)
committerPhilipp Hahn <hahn@univention.de>
Thu, 8 Dec 2011 17:15:16 +0000 (17:15 +0000)
Fix insufficient quoting between "tap-ctl list" and
xend/server/BlktapController.py

The "line.split(None, 4)" needs to be a "3", because 3 splits needs to
be done to get the 4 parts.  Sorry for the mixup.

[ fix to 24335:3915bd95ade5. -iwj ]

Committed-by: Ian Jackson <ian.jackson@eu.citrix.com>
tools/python/xen/xend/server/BlktapController.py

index 51647e2d92007efc313c9152cd8ccd3e0db0fe04..60079ebe81c1b7aa290255dacdabb0d9a019bef9 100644 (file)
@@ -253,7 +253,7 @@ class TapdiskController(object):
             tapdisk = TapdiskController.Tapdisk()
 
             # Since 'tap-ctl list' does not escape blanks in the path, hard-code the current format using 4 pairs to prevent splitting the path
-            for pair in line.split(None, 4):
+            for pair in line.split(None, 3):
                 key, value = pair.split('=', 1)
                 if key == 'pid':
                     tapdisk.pid = value